package com.meida.module.bus.client.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.meida.common.mybatis.annotation.TableAlias;
import com.meida.common.mybatis.base.entity.AbstractAllEntity;
import com.meida.common.mybatis.base.entity.AbstractEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.math.BigDecimal;

/**
 * 用户商品表
 *
 * @author flyme
 * @date 2022-03-01
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("app_user_goods")
@TableAlias("appUserGoods")
@ApiModel(value = "AppUserGoods对象", description = "用户商品表")
public class AppUserGoods extends AbstractAllEntity {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键")
    @TableId(value = "userGoodsId", type = IdType.ASSIGN_ID)
    private Long userGoodsId;

    @ApiModelProperty(value = "商品Id")
    private Long goodsId;

    @ApiModelProperty(value = "合作商Id")
    private String distributorId;

    @ApiModelProperty(value = "商品Id")
    private Integer goodsNum;

    @ApiModelProperty(value = "1扫码注册，2商城购买，3销售新增，4后台新增，5后台导入,6礼品卡接收")
    private Integer sourceType;

    @ApiModelProperty(value = "所属分类")
    private Long categoryId;

    @ApiModelProperty(value = "业务Id(线上为orderdetailId)")
    private Long businessId;

    @ApiModelProperty(value = "所属销售")
    private Long employeeId;

    @ApiModelProperty(value = "所属用户")
    private Long userId;

    @ApiModelProperty(value = "(1是，2否)是否是会员卡")
    private Integer isVipCard;

    private String vipcardCategoryCode;

    @ApiModelProperty(value = "会员卡号")
    private String vipCardNo;

    /**
     * 0 未激活 1正常、2已过期、3未开通、4未通过、5冻结、6退卡中、7已退卡、8已转卡、9已转赠
     */
    @ApiModelProperty(value = "会员卡状态")
    private Integer vipCardState;

    @ApiModelProperty(value = "二维码")
    private String qrCode;

    @ApiModelProperty(value = "开卡地")
    private String area;

    /**
     * (其它物品销售经理所在区域)
     */
    @ApiModelProperty(value = "开卡地")
    private Long airportId;

    @ApiModelProperty(value = "要客卡公司名称")
    private String companyName;

    @ApiModelProperty(value = "礼品卡激活码")
    private String activateCode;

    @ApiModelProperty(value = "使用验证(非卡，单次物品使用）（1未使用，2已使用）")
    private Integer useState;

    @ApiModelProperty(value = "0未申请，1申请中，2已取消，3已退款")
    private Integer refundState;

    @ApiModelProperty(value = "退卡日期")
    private String refundDate;

    @ApiModelProperty(value = "0订单退款，1现办现退")
    private Integer refundSourceType;

    @ApiModelProperty(value = "1新会员，2老会员")
    private Integer isNew;

    @ApiModelProperty(value = "(1已给，2未给)实体卡")
    private Integer isGive;

    @ApiModelProperty(value = "会员卡绑定的个人资料信息")
    private Long privateDataId;

    @ApiModelProperty(value = "是否完善资料（会员卡1已完善，2未完善）")
    private Integer isPrivatedata;

    @ApiModelProperty(value = "是否转过卡（1未转过，2已转过）")
    private Integer isTransfered;

    @ApiModelProperty(value = "转赠人Id(现在所属人)")
    private String transferedAccountId;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "支付方式")
    private String payType;

    @ApiModelProperty(value = "线下支付方式")
    private Long paywayId;

    @ApiModelProperty(value = "支付Id(讯联支付，银联支付)")
    private String payInfoId;

    @ApiModelProperty(value = "支付渠道")
    private Long payparamId;

    @ApiModelProperty(value = "支付金额")
    private BigDecimal payAmount;

    @ApiModelProperty(value = "购买日期（生效日期）")
    private String buyDate;

    @ApiModelProperty(value = "过期日期")
    private String expireDate;

    @ApiModelProperty(value = "提交退卡申请(1未提交，2已提交)")
    private Integer isBacksub;

    @ApiModelProperty(value = "(转卡赠卡接收者(1(不是，2是)))")
    private Integer isReceiver;

    @ApiModelProperty(value = "转卡日期")
    private String transferDate;

    @ApiModelProperty(value = "是否升过级")
    private Integer isUpgrade;

    @ApiModelProperty(value = "升级前的商品Id")
    private String oldGoodsId;

    @ApiModelProperty(value = "升级日期")
    private String upgradeDate;

    private String upgradeUserId;

    @ApiModelProperty(value = "所属公众号")
    private Long weChatId;

    @ApiModelProperty(value = "合卡销售")
    private String heKaRemark;

    @ApiModelProperty(value = "激活日期")
    private String activateDate;

    @ApiModelProperty(value = "客户手机号")
    private String agentMobile;

    @ApiModelProperty(value = "代理商备注")
    private String agentRemark;

    @ApiModelProperty(value = "最新标签")
    private String newestTagRemark;

    @ApiModelProperty(value = "卡种协议")
    private String agreement;

    @ApiModelProperty(value = "是否展示")
    private Integer isShowData = 0;

}
